<?php
/**
 * <https://y.st./>
 * Copyright © 2017 Alex Yst <mailto:copyright@y.st>
 * 
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * 
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program. If not, see <https://www.gnu.org./licenses/>.
**/

$xhtml = array(
	'<{title}>' => 'Jimmying the lock',
	'<{body}>' => <<<END
<img src="/img/CC_BY-SA_4.0/y.st./weblog/2017/09/28.jpg" alt="Strange, lumpy fruits" class="framed-centred-image" width="800" height="480"/>
<section id="general">
	<h2>General news</h2>
	<p>
		Since installing the lock on my bedroom, I&apos;ve been eyeing the crack between the doorway and the door.
		There&apos;s way too much of a gap, and I&apos;ve figured jimmying the lock wouldn&apos;t be that hard.
		Today, I tried it, and as expected, the lock was easily bypassed.
		I can&apos;t entirely fix the problem without either replacing the door with a wider one or ripping the moulding off that side of the doorway and replacing it with a thicker one.
		However, I&apos;ve cut the ends off a couple bike tire valve caps and used them as washers to hold the metal plate the latch fits into closer to the door.
		I&apos;d like to replace those with real washers at some point, but this should do for now.
		I&apos;m sure it&apos;s still possible to jimmy the lock, but it&apos;s much more inconvenient to do so now, and I couldn&apos;t get the door open with my short attempt, while before this operation, I got it open while barely even trying.
		If my mother were a stalker or something, this setup would be nowhere near secure enough.
		As it is though, I only need to make it inconvenient enough to get in that she doesn&apos;t even bother.
	</p>
	<p>
		I came up with a couple new ideas for Minetest.
		The first idea was stupid, and I likely won&apos;t use it: a &quot;clay mode&quot; setting for <code>minestats</code>.
		If the server administrator sets this to active, the mod will track the harvesting of nodes such as clay nodes, that drop the craft items needed to craft the original node instead of dropping the node itself.
		Personally, I think such stats are useless and serve only to make some players craft the node repeatedly and dig it back up to increase the stat.
		It doesn&apos;t take actually playing the game to raise those stats, and actually (I think) would encourage players to do stupid, pointless, and boring crafting/digging that yields them no extra resources just to see the number go up.
		And once <code>minequest</code> is involved, they have even more reason to work at upping that nonsense stat.
		No, it&apos;s probably better if I leave the clay filter on with no setting for removing it.
	</p>
	<p>
		The second idea is for a second mod, likely called <code>statsmod</code>.
		<code>statsmod</code> would modify the stats to lower a player&apos;s visible and effective stats when they consume minerals.
		How this is implemented would be tricky business though.
		If I attach the lowering to, for example, the crafting of a tool, players can use a second account to do the crafting, keeping their main account free of deductions and the bogus account in the negative range.
		If I attach the penalty to the breaking of a tool, players simply would need to avoid finishing off their tools, and will actually waste the tool stubs.
		I think the best option, with tools anyway, is to attach the penalty to the <strong>*using*</strong> of the tool.
		When a tool takes wear, if I can figure out how to implement this, a fraction of a point will be removed from the player based on the amount of a mineral needed to craft the tool and the amount of wear taken by the tool.
		The usage penalties of a tool crafted and used until it breaks would add up to equal the number of the mineral used to craft the tool.
		There are some tricky bits here though, even if the $a[API] has every capability I need for making it easy.
		I don&apos;t think the right $a[API] components exist for easily tapping into tool wear while knowing what player is causing the wear.
		I&apos;ve actually tried to get the information I&apos;d need for this out of the $a[API] for the per-player, reduced tool wear feature, so I already know trying this will be a major pain and I&apos;d likely fail.
		Even if I found a way though, there&apos;s still the matters of fires and fuels, at a minimum.
		With fuels, how do I measure consumption?
		The best idea I can come up with is to deduct points when fuel is added to the furnace, and for both consistency and to avoid deductions for fuels not consumed, give points back when fuels are removed from the furnace.
		Furnaces can be used by multiple players though.
		This system is vulnerable to the same one the deduct-on-tool-craft system is vulnerable to: a second account can be set up to take the loss.
		Additionally, however, it also has the added vulnerability that points can be transferred from one player to another.
		One player can load the furnace and another can empty it.
		Something would need to be done to patch these flaws.
		Finally, there&apos;s fire.
		If you light a fire and burn up your mineral-based goods, the same sorts of deductions should take place.
		So how do we know which player is responsible for the destruction caused by a given fire?
		I think in theory, this mod is a very good idea.
		It adds a new element to the game, when combined with <code>minequest</code>: you can build your power to use with the bonuses or you can spend your power for temporary convenience.
		However, in practice, this mod may never be able to come to fruition.
	</p>
</section>
<section id="university">
	<h2>University life</h2>
	<p>
		Last week, we were instructed to register for a third-party website and take half of a specific course there.
		No course by the specified name seemed to exist though, so I took about a course and a half of other courses that looked like it was about the right thing.
		But now, this week, we need to finish up this seemingly-non-existent course and provide a screenshot showing this completion.
		We&apos;re actually being graded on this now, and no such course can be found.
		I decided to hit up the course forum at my school to ask for help, but someone there already did.
		No conclusive answer was ever given and the professor seems not to have seen the question.
		Other students responded, and they didn&apos;t know where to find the course either.
		There are at least five of us that can&apos;t find this course, so I&apos;m inclined to believe it isn&apos;t there and that the third-party website was restructured at some point ion the past.
	</p>
	<p>
		I was supposed to complete a total of twelve lessons in one course, a course that seems to no longer exist.
		I instead completed a total of ten lessons in two courses that looked to be the equivalent of the course I was told to take.
		(I was told to take the $a[HTML] and $a[CSS] course, which doesn&apos;t exist, but I took the $a[HTML] course and the $a[CSS] course.)
		Being two lessons short, I was tempted to take a third course to try to make up for it, but the other courses don&apos;t look like what we&apos;re studying, so I stopped there.
		I&apos;ve completed that assignment, at least as best I can figure out how to.
	</p>
</section>
END
);
